<!--
*@Author: QWP
*@Description: 非煤企业的详情
*@Date: 2024-11-15 09:09:49
-->
<template>
  <u-drawer v-bind="$attrs"
    title="非煤矿企业风险详情"
    :maskClosable="true"
    width="40%"
    class="u-coal-detial-drawer">
    <a-layout class="f-h-100">
      <u-table-header style="padding: 0;">
        <u-busi-card title="企业信息"
          style="position: relative">
          <u-form :elements="formEls"
            :model="data"
            :gutter="16"
            :loading="loading"
            class="u-security-detial-form"
            ref="formRef">
          </u-form>
        </u-busi-card>
      </u-table-header>
      <u-table-content>
        <WarningDispose :params="data" 
          :showTitle="false"
          ref="WarningDisposeRef"
          v-bind="$attrs"/>
      </u-table-content>
    </a-layout>
  </u-drawer>
</template>

<script lang='ts' setup>
import { ref, reactive, computed, onMounted, watch, useAttrs, h } from 'vue' 
import WarningDispose from '@/views/oa/warning/sumWarning/WarningDisposeF.vue'

const props = defineProps<{
  data: any,
}>()

const attrs = useAttrs()

const labelWidth = '100px'
const formEls: Array<_IFormEl> = reactive([
  { label: '企业名称', key: 'companyName', col: { span: 24 }, element: 'text', 
    formItemProps: { labelWidth } 
  },
  { label: '企业类型', key: 'companyType', col: { span: 24 }, element: 'text', 
    formItemProps: { labelWidth } 
  },
])

watch(() => attrs.open, (nval, oval) => {
  if(nval == true) {
    // activeKey.value = tabs[0]['key']
  }
})
</script>

<style lang='scss'>
.u-coal-detial-drawer {
  .ant-drawer-body {
    padding: 0 12px
  }
  .u-qr-srcurity{
    position: absolute; 
    top: -18px; 
    right: 0; 
    display: flex; 
    flex-direction: column;
    justify-content: center;
    b {
      text-align: center;
    }
  }
  .u-security-detial-form {
    .ant-form-item-label {
      font-weight: bold;
    }
  }
  .u-detial-tab-s {
    height: 100%;
    .ant-tabs-content {
      height: 100%
    }
  }
}
</style>